#ifndef TEAM_H
#define TEAM_H

#include <qlist.h>
#include <qstring.h>

class Unit;

enum TeamNumber {NO_TEAM, PLAYER_TEAM, COMPUTER_TEAM};

class Team : public QList<Unit*>
{
public:
    Team(quint8 number, const QString& name = "Undefined");

    void append(Unit* unit);
    void append(const QList<Unit*>& units);
    bool removeOne(Unit* unit); //returns true if the unit was actually removed; otherwise returns false

    quint8 getNumber() const;
    const QString& getName() const;

    void setNumber(quint8 n) { m_number = n; }
    void setName(QString m) { m_name = m; }

private:
    quint8 m_number;
    QString m_name;
};

#endif // TEAM_H
